﻿using System;

namespace Mr.HttpBodyWrapper
{
    public class QueryParameter : IQueryParameter
    {
        public QueryParameter()
            : this(string.Empty, string.Empty)
        {

        }

        public QueryParameter(string name, string value)
        {
            this.Name = name;
            this.Value = value;
            this.ContentType = "application/x-www-form-urlencoded";
        }

        public string Name { get; set; }

        public string Value { get; set; }

        public string ToParamString()
        {
            return this.Name + "=" + this.Value;
        }

        public string ContentType { get; set; }
    }
}
